package com.dreamwhale.machinery.user.controller;


import com.dreamwhale.machinery.config.DataResult;
import com.dreamwhale.machinery.user.service.YxUserBillService;
import com.dreamwhale.machinery.user.service.YxUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 用户账单表 前端控制器
 * </p>
 *
 * @author Author
 * @since 2020-05-27
 */
@RestController
@RequestMapping("/yxUserBill")
public class YxUserBillController {

    @Autowired
    private YxUserBillService yxUserBillService;

    @GetMapping("/transactionRecords")
    /**
     * @MethodName : getUserBill
     * @Description : 查询交易记录
     * @param : user
     * @param : page
     * @Author : DragonUncle
     * @Data : 10:51 2020/6/30
     * @return : 
     */
    public ResponseEntity<DataResult> getUserBill(Integer user, Integer page) {
        return ResponseEntity.ok(yxUserBillService.getUserBill(user, page));
    }

}

